package sprites;

import controlador.GestorDeDibuix;
import java.awt.Point;

/**
 *
 * @author Carlos Moya Martinez
 */
public class Bullet extends PlayableElement {

    public Bullet(int x, int y, Point pantalla) {
        super(1, false, x, y, pantalla);
        this.dimX = 10;
        this.dimY = 10;
        this.enemic = false;
    }

    @Override
    public void animar() {
        this.y = this.y - 2;
        if (this.y < 0) {
            this.vides = 0;
        }
    }

    @Override
    public void pintar() {
        GestorDeDibuix.getInstancia().pintar("PLASMA", getX()-(this.dimX/2), getY()-(this.dimY/2), dimX, dimY);
    }
}
